#!/usr/bin/env python3
import socket
import json


BUFSIZE = 1024
client = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
ip_port = ('127.0.0.1', 9998)
#ip_port = ('10.39.245.93', 9998)

operate = "face_add" #face_add   face_del
url = "http://0.0.0.0:8000/officePic/9_djf_0_9_0.jpg"  
faceid = "djf"
passid = "pass_"+faceid

dict = {}
dict.update({'operate':operate})
dict.update({'url':url})
dict.update({'faceid':faceid})
dict.update({'passid':passid})

commandmsg = json.dumps(dict)

# 发布消息
client.sendto(commandmsg.encode('utf-8'), ip_port)
